package edu.biwu.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@RequestMapping("/product")
@Controller
public class ProductController {

    @GetMapping("/list.do")
    public @ResponseBody String list(){// @ResponseBody 注解将返回值作为响应体返回 不加注解则返回视图名称
        System.out.println("查询商品信息");
//        int i = 1/0;
        return "success";
    }
}
